#include "state.h"
#include "process.h"
#include "arg.h"

#include <iostream>
#include <cstdlib>

using namespace std;

int main(int argc, char** argv)
{
    Process process(argc, argv);

/*
    double time;
    int n,k;
    arg(argc, argv, n, k);

    complexd h[] = {
        complexd(1/sqrt(2), 0), complexd( 1/sqrt(2), 0),
        complexd(1/sqrt(2), 0), complexd(-1/sqrt(2), 0),
        complexd(1/sqrt(2), 0), complexd( 1/sqrt(2), 0),
        complexd(1/sqrt(2), 0), complexd(-1/sqrt(2), 0)
    };
    Conversion H(2,2,h);

    State state(n);


    time = process.getTime();

    state.randomFill();
    state.norma();
    state.doConversion(H,1);

    time = process.getTime() - time;

    if (state.getRank() == 0) {
        cout << "Size = " << state.getSize();
        cout << " State length = " << n << " do kbit = 1";
        cout << ". Time = " << time << endl;
    }

    time = process.getTime();

    state.randomFill();
    state.norma();
    state.doConversion(H,16);

    time = process.getTime() - time;

    if (state.getRank() == 0) {
        cout << "Size = " << state.getSize();
        cout << " State length = " << n << " do kbit = 16 ";
        cout << ". Time = " << time << endl;
    }

    time = process.getTime();

    state.randomFill();
    state.norma();
    state.doConversion(H,n);

    time = process.getTime() - time;

    if (state.getRank() == 0) {
        cout << "Size = " << state.getSize();
        cout << " State length = " << n << " do kbit = " << n;
        cout << ". Time = " << time << endl;
    }

*/
   return 0;
}
